<?php

class Application_Form_Cloudinary extends Zend_Form {

    public function init() {
        $this->setMethod("post");

        $cloudname = new Zend_Form_Element_Text('cloudName');
        $cloudname->setLabel("Enter Cloud Name:")
                ->setRequired()
                ->addFilter("StringTrim")
                ->setAttribs(array('class' => 'span12'));

        $apikey = new Zend_Form_Element_Text('apiKey');
        $apikey->setLabel("Enter Api Key:")
                ->setRequired()
                ->addFilter("StringTrim")
                ->setAttribs(array('class' => 'span12'));

        $apisecret = new Zend_Form_Element_Text('apiSecret');
        $apisecret->setLabel("Enter Api Secret:")
                ->setRequired()
                ->addFilter("StringTrim")
                ->setAttribs(array('class' => 'span12'));

        $id = new Zend_Form_Element_Hidden('id');
        $id->setValue(0);

        $submit = new Zend_Form_Element_Submit('submit');
        $submit->setLabel("Save")
                ->setAttribs(array('class' => 'btn btn-success'));

        $this->addElements(array($cloudname, $apikey, $apisecret, $id, $submit));
    }

}

